package com.king.oa.domain;

import java.util.Date;
import java.util.HashSet;
import java.util.Set;

/**
 * 论坛主题
 * 
 * @author KingSir
 *
 */
public class Topic extends Article {

	/** 普通帖 */
	public static final int TYPE_NORMAL = 0;
	
	/** 精华帖 */
	public static final int TYPR_BEST = 1;
	
	/** 置顶帖 */
	public static final int TYPR_TOP = 2;
	
	private Forum forum;//所属的版块
	private Set<Reply> replies = new HashSet<>();//所有的文章
	
	private int type;//类型
	private int replyCount;//所有的回复数量
	private Reply lastReply;//最后的回复
	private Date lastUpdateTime;//最后更新的时间(主题发表时间或者是最后回复的时间)
	
	public Forum getForum() {
		return forum;
	}
	
	public void setForum(Forum forum) {
		this.forum = forum;
	}
	
	public Set<Reply> getReplies() {
		return replies;
	}
	
	public void setReplies(Set<Reply> replies) {
		this.replies = replies;
	}
	
	public int getType() {
		return type;
	}
	
	public void setType(int type) {
		this.type = type;
	}
	
	public int getReplyCount() {
		return replyCount;
	}
	
	public void setReplyCount(int replyCount) {
		this.replyCount = replyCount;
	}
	
	public Reply getLastReply() {
		return lastReply;
	}
	
	public void setLastReply(Reply lastReply) {
		this.lastReply = lastReply;
	}
	
	public Date getLastUpdateTime() {
		return lastUpdateTime;
	}
	
	public void setLastUpdateTime(Date lastUpdateTime) {
		this.lastUpdateTime = lastUpdateTime;
	}
	
}
